package org.example.mall4j.Controller;


import org.example.mall4j.Roles.IsAdmin;
import org.example.mall4j.pojo.SysUser;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class UserController {
//    @PostMapping("/login")
//    public SysUser login(@RequestBody SysUser sysUser)
//    {
//        System.out.println(sysUser);
//        return null;
//    }
    @PostMapping("/test")
    @IsAdmin
    public String test()
    {
        return "admin";
    }
}
